//
//  BaseViewController.m
//  TableBarControllerDemo
//
//  Created by 边果互动 on 2021/3/15.
//

#import "BaseViewController.h"

@interface BaseViewController ()

@end

@implementation BaseViewController

- (void)viewDidLoad {
    [super viewDidLoad];
    // Do any additional setup after loading the view.
//    self.navigationController.navigationBar.translucent = NO;
    self.view.backgroundColor = [UIColor whiteColor];
    self.navigationController.interactivePopGestureRecognizer.delegate = (id) self;
}

/*
#pragma mark - Navigation

// In a storyboard-based application, you will often want to do a little preparation before navigation
- (void)prepareForSegue:(UIStoryboardSegue *)segue sender:(id)sender {
    // Get the new view controller using [segue destinationViewController].
    // Pass the selected object to the new view controller.
}
*/

#pragma mark - 给指定View添加阴影
- (void) addShadow: (UIView *) view {
    //    向左偏移10 （-10，0）
    //    向右偏移10 （10，0）
    //    向上偏移10 （0，-10）
    //    向下偏移10 （0，10）
        view.layer.shadowOffset =CGSizeMake(0, 2);
        view.layer.shadowColor = Shadow_Color.CGColor;
        view.clipsToBounds = NO;
    //    view.layer.shadowRadius = 10;
        view.layer.shadowOpacity = .1f;
        CGRect shadowFrame = view.layer.bounds;
    //
        CGPathRef shadowPath = [UIBezierPath bezierPathWithRect:shadowFrame].CGPath;
        view.layer.shadowPath = shadowPath;
        //设置缓存仅用于设置此选项。
        [view.layer setShouldRasterize:YES];
        //设置对应比例，防止cell出现模糊和锯齿
        [view.layer setRasterizationScale:[UIScreen mainScreen].scale];
}

@end
